<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class Auth_OpenID_SessionNegotiator</title>
			<link rel="stylesheet" href="../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			
<h2 class="class-name">Class Auth_OpenID_SessionNegotiator</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
															<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">A session negotiator controls the allowed and preferred association  types and association session types. Both the <a href="../OpenID/Auth_OpenID_Consumer.html">Auth_OpenID_Consumer</a> and <a href="../OpenID/Auth_OpenID_Server.html">Auth_OpenID_Server</a> use  negotiators when creating associations.</p>
<p class="description"><p>You can create and use negotiators if you: <ul><li>Do not want to do Diffie-Hellman key exchange because you use</li></ul> transport-layer encryption (e.g. SSL)</p><p><ul><li>Want to use only SHA-256 associations</li></ul> <ul><li>Do not want to support plain-text associations over a non-secure</li></ul> channel</p><p>It is up to you to set a policy for what kinds of associations to  accept. By default, the library will make any kind of association  that is allowed in the OpenID 2.0 specification.</p><p>Use of negotiators in the library  =================================</p><p>When a consumer makes an association request, it calls <a href="../OpenID/Auth_OpenID_SessionNegotiator.html#methodgetAllowedType">getAllowedType</a> to get the preferred association type and  association session type.</p><p>The server gets a request for a particular association/session type  and calls <a href="../OpenID/Auth_OpenID_SessionNegotiator.html#methodisAllowed">isAllowed</a> to determine if it should create an  association. If it is supported, negotiation is complete. If it is  not, the server calls <a href="../OpenID/Auth_OpenID_SessionNegotiator.html#methodgetAllowedType">getAllowedType</a> to get an allowed  association type to return to the consumer.</p><p>If the consumer gets an error response indicating that the  requested association/session type is not supported by the server  that contains an assocation/session type to try, it calls <a href="../OpenID/Auth_OpenID_SessionNegotiator.html#methodisAllowed">isAllowed</a> to determine if it should try again with the given  combination of association/session type.</p></p>
		<p class="notes">
			Located in <a class="field" href="_Auth---OpenID---Association.php.html">/Auth/OpenID/Association.php</a> (line <span class="field">518</span>)
		</p>
		
				
		<pre></pre>
	
			</div>
</div>




	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
												<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
																																						
				<div class="method-definition">
											<span class="method-result">Auth_OpenID_SessionNegotiator</span>
										<a href="#Auth_OpenID_SessionNegotiator" title="details" class="method-name">Auth_OpenID_SessionNegotiator</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$allowed_types</span>)
									</div>
														
				<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#getAllowedType" title="details" class="method-name">getAllowedType</a>
										()
									</div>
														
				<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#isAllowed" title="details" class="method-name">isAllowed</a>
											(<span class="var-type"></span>&nbsp;<span class="var-name">$assoc_type</span>, <span class="var-type"></span>&nbsp;<span class="var-name">$session_type</span>)
									</div>
											</div>
		</div>
	</div>		

	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
																<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>
<a name="methodAuth_OpenID_SessionNegotiator" id="Auth_OpenID_SessionNegotiator"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">Constructor Auth_OpenID_SessionNegotiator</span> (line <span class="line-number">519</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	
	<div class="method-signature">
		<span class="method-result">Auth_OpenID_SessionNegotiator</span>
		<span class="method-name">
			Auth_OpenID_SessionNegotiator
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$allowed_types</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$allowed_types</span>			</li>
				</ul>
		
			
	</div>
<a name="methodgetAllowedType" id="getAllowedType"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">getAllowedType</span> (line <span class="line-number">594</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get a pair of assocation type and session type that are  supported.</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			getAllowedType
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodisAllowed" id="isAllowed"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">isAllowed</span> (line <span class="line-number">579</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			isAllowed
		</span>
					(<span class="var-type"></span>&nbsp;<span class="var-name">$assoc_type</span>, <span class="var-type"></span>&nbsp;<span class="var-name">$session_type</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"></span>
				<span class="var-name">$assoc_type</span>			</li>
					<li>
				<span class="var-type"></span>
				<span class="var-name">$session_type</span>			</li>
				</ul>
		
			
	</div>
						
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Wed, 05 Dec 2007 14:02:10 -0800 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.3.2</a>
	</p>
	</div></body>
</html>